package com.etoak.controller;

import com.etoak.entity.User;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
@RequestMapping("/user")
public class UserController {

    @GetMapping("/{id}")
    public User getById(@PathVariable int id) {
        User user = new User(id,"测试名","测试邮箱");
        return user;
    }
}
